<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<%@ page contentType="text/html; charset=UTF-8"%>
<%@ page pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<html>
	<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <script type="text/javascript">
    	$(document).ready(function(){
    		$('#del_finger_menu').menu(); 
    		$('#vendor').combobox({onLoadSuccess:reset_vendor});
     		$('#reg_cfinger_detail_panel').window({onClose:reset_finger_temp,
     		onOpen:function(){
     			$('#vendor').combobox('reload','queryVendors.action');
     		}});
    		
     		$('#save').click(function (){
     		  $('#linkfinger').val(get_linked_finger());
    		  $('#reg_cfinger_form').form('submit', {
    		    url: 'regCustomerFinger.action',
    		    error:function(message){
    		    	alert('提交数据错误，服务器可能已关闭！系统返回:'+message);
    		  	},
    		    success:function(data){
    		      var a = eval('(' + data + ')');
    		      $.messager.alert('注册客户指纹', a.message, 'info');
    		      
    		      if (a.result=='0'){
                      var $tbl = $('#customer_table');
                      var row = $tbl.datagrid('getSelected');
                      var index = $tbl.datagrid('getRowIndex',row);
                      $tbl.datagrid('deleteRow', index);
    		        $('#reg_cfinger_detail_panel').window('close');
    		      }
    		    }
    		    })
    		});

     		$('#cancel').click(function (){
     			$('#reg_cfinger_detail_panel').window('close');
    		});
    	});
    </script>
	</head>
	<body>
	
    <div id="reg_cfinger_detail_panel" collapsible="false" fit="false" title="注册客户指纹" 
    	resizable="false" collapsible="false" minimizable="false" maximizable="false" 
    	closable="true" closed="true" icon="icon-save" modal="true" class="jquery_window">
    	<s:form id="reg_cfinger_form" action="regCustomerFinger" cssStyle="margin:20px,50px">
    		<s:hidden id="linkfinger" name="linkfinger"/>
    		<s:include value="/app/finger_info.jsp"></s:include>
    		<table>
    			<tr height="24px">
    				<td><s:label value="所属机构："></s:label></td>
    				<td width="220px"><s:label id="deptno"></s:label></td>
    			</tr>
    			<tr height="24px">
    				<td><s:label value="身份证号："></s:label></td>
    				<td width="220px"><s:label id="identifyno"></s:label>
    				<s:hidden id="identifyno_val" name="identifyno"/></td>
    			</tr>
    			<tr height="24px">
    				<td><s:label value="姓名："></s:label></td>
    				<td width="220px"><s:label id="name"></s:label></td>
    			</tr>
    			<tr height="24px">
    				<td><s:label value="指纹厂商:" for="vendor"/></td>
    				<td width="220px"><input valueField="vendorid" textField="vendorname" 
    					id="vendor" name="vendor" class="easyui-combobox" 
    					editable="false" panelHeight="auto"/></td>
    			</tr>
    			<tr><td colspan="2"><s:include value="/app/finger_hand.jsp"></s:include></td></tr>
    			<tr>
    				<td colspan="2" align="center">
            			<button id="save" class="buttons_css" style="width:70px">
            				<label style="70px" class="save_css">保存</label></button>
            			<label style="width:20px"></label>
            			<button id="cancel" class="buttons_css" style="width:70px">
            				<label style="70px" class="cancel_css">返回</label></button>
    				</td>
    			</tr>
    		</table>
    	</s:form>
    </div>
    </body>
</html>